<!DOCTYPE html>
<html lang="zh-CN">

	<head>
		<base href="../" />
		<meta charset="utf-8">
		<meta http-equiv="X-UA-Compatible" content="IE=edge">
		<meta name="viewport" content="width=device-width, initial-scale=1">
		<title>新闻管理</title>

		<link href="css/bootstrap.min.css" rel="stylesheet">
		<link href="css/bootstrap-cerulean.min.css" rel="stylesheet">

		<link rel="stylesheet" href="css/font-awesome.min.css" />
		<link rel="stylesheet" href="css/animate.min.css" />
	</head>

	<body>
		<nav class="navbar navbar-default">
			<div class="container-fluid">
				<!-- Brand and toggle get grouped for better mobile display -->
				<div class="navbar-header">
					<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1" aria-expanded="false">
                <span class="sr-only">Toggle navigation</span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
              </button>
					<a class="navbar-brand" href="#">Brand</a>
				</div>

				<!-- Collect the nav links, forms, and other content for toggling -->
				<div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
					<ul class="nav navbar-nav">
						<li class="active">
							<a href="#">Link <span class="sr-only">(current)</span></a>
						</li>
						<li>
							<a href="#">Link</a>
						</li>
						<li class="dropdown">
							<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">Dropdown <span class="caret"></span></a>
							<ul class="dropdown-menu">
								<li>
									<a href="#">Action</a>
								</li>
								<li>
									<a href="#">Another action</a>
								</li>
								<li>
									<a href="#">Something else here</a>
								</li>
								<li role="separator" class="divider"></li>
								<li>
									<a href="#">Separated link</a>
								</li>
								<li role="separator" class="divider"></li>
								<li>
									<a href="#">One more separated link</a>
								</li>
							</ul>
						</li>
					</ul>
					<form class="navbar-form navbar-left">
						<div class="form-group">
							<input type="text" class="form-control" placeholder="Search">
						</div>
						<button type="submit" class="btn btn-default">Submit</button>
					</form>
					
					<ul class="nav navbar-nav navbar-right">
						<li>
							<a href="#">Link</a>
						</li>
						<li class="dropdown">
							<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">Dropdown <span class="caret"></span></a>
							<ul class="dropdown-menu">
								<li>
									<a href="#">Action</a>
								</li>
								<li>
									<a href="#">Another action</a>
								</li>
								<li>
									<a href="#">Something else here</a>
								</li>
								<li role="separator" class="divider"></li>
								<li>
									<a href="#">Separated link</a>
								</li>
							</ul>
						</li>
					</ul>
				</div>
				<!-- /.navbar-collapse -->
			</div>
			<!-- /.container-fluid -->
		</nav>

		<div class="container">

			<ol class="breadcrumb">
				<li>
					<a href="#">Home</a>
				</li>
				<li>
					<a href="#">Library</a>
				</li>
				<li class="active">Data</li>
			</ol>

			<div class="panel panel-primary">
				<!-- Default panel contents -->
				<div class="panel-heading"><i class="
glyphicon glyphicon-th-large"></i> 新闻列表</div>
				<div class="panel-body">
					<form class="form-inline" id="searchForm">
						<div class="form-group">
							<input type="text" name="key" class="form-control" placeholder="标题关键字">
						</div>
						<button type="submit" class="btn btn-primary"><i class="fa fa-search"></i></button>
						<button type="button" data-toggle="modal" data-target="#addDialog" class="btn btn-danger pull-right"><i class="fa fa-plus"></i></button>
					</form>
				</div>
				<table class="table table-bordered table-striped table-hover">
					<thead>
						<tr>
							<th>#</th>
							<th>新闻标题</th>
							<th>发布时间</th>
							<th>作者</th>
							<th>操作</th>
						</tr>
					</thead>
					<tbody id="dataGridLoading" style="display: none;">
						<tr>
							<td colspan="5" class="text-center" style="padding: 5rem 0;">

								<i class="fa fa-spinner fa-pulse fa-4x fa-fw"></i>

							</td>

						</tr>

					</tbody>

					<tbody id="dataGrid">

						<tr>
							<th scope="row" class="_rowNum">1</th>
							<td class="_newsTitle">宁夏中卫：黄沙戈壁成创新热土</td>
							<td class="_newsTime">2019-10-24 17:29</td>
							<td class="_newsWorker">光明网</td>
							<td>
							<!-- dssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssss -->
								<a class="_update"   href="javascript:void(0)"  data-toggle="modal" data-target="#updateDialog">修改</a>
								
								<a class="_del" href="javascript:void(0);">删除</a>
							</td>
						</tr>

					</tbody>
				</table>
			</div>

			<div class="text-center">
				<nav aria-label="Page navigation">
					<ul class="pagination">
						<li data-page="1">
							<a href="javascript:void(0);" aria-label="Previous">
								<span aria-hidden="true">«</span>
							</a>
						</li>
						<li data-page="1">
							<a href="javascript:void(0);">1</a>
						</li>
						<li data-page="1">
							<a href="javascript:void(0);" aria-label="Next">
								<span aria-hidden="true">»</span>
							</a>
						</li>
					</ul>
				</nav>

				<br/>
				<i class="fa fa-address-book animated bounceIn" style="font-size: 136px; color: red;"></i>

			</div>

		</div>
		
		
		
<!-- 删除确认对话框  -->		
<div id="delDialog" class="modal fade" tabindex="-1" role="dialog">
  <div class="modal-dialog" role="document">
    <div class="modal-content">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
        <h4 class="modal-title">确认对话框</h4>
      </div>
      <div class="modal-body">
        您是否确定要删除呢？
      </div>
      <div class="modal-footer">
        <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
        <button type="button" class="btn btn-primary _confirm" data-dismiss="modal">确认</button>
      </div>
    </div><!-- /.modal-content -->
  </div><!-- /.modal-dialog -->
</div><!-- /.modal -->


<!-- 添加对话框  -->		
<div id="addDialog" class="modal fade" tabindex="-1" role="dialog">
  <div class="modal-dialog" role="document" style="width: 1000px;">
    <div class="modal-content">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
        <h4 class="modal-title">添加新闻</h4>
      </div>
      <div class="modal-body">
 <form id="addForm" class="form-horizontal">
  <div class="form-group">
    <label class="col-sm-2 control-label">标题</label>
    <div class="col-sm-10">
      <input type="text" name="newsTitle" class="form-control"  placeholder="">
    </div>
  </div>
  <div class="form-group">
    <label class="col-sm-2 control-label">作者</label>
    <div class="col-sm-4">
      <input type="text" name="newsWorker" class="form-control"  placeholder="">
    </div>
  </div>
  <div class="form-group">
    <label class="col-sm-2 control-label">类别</label>
    <div class="col-sm-4">
      <select name="newsClassId" class="form-control"></select>
    </div>
  </div>
  
  <div class="form-group">
    <label class="col-sm-2 control-label">内容</label>
    <div class="col-sm-10">
      <textarea name="newsContent" class="form-control" style="height: 15em;"></textarea>
    </div>
      
  </div>
  
  <div class="form-group">
    <div class="col-sm-offset-2 col-sm-10">
    	<button type="submit" class="btn btn-primary _confirm" >发布文章</button>
       <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
        
    </div>
  </div>
</form>
      </div>

    </div><!-- /.modal-content -->
  </div><!-- /.modal-dialog -->
</div><!-- /.modal -->

<!-- 修改界面 -->
<div id="updateDialog" class="modal fade" tabindex="-1" role="dialog">
     <div class="modal-dialog" role="document">
         <div class="modal-content">
          <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
        <h4 class="modal-title">修改新闻</h4>
      </div>
 <form id="updateForm" class="form-horizontal">
  <div class="form-group">
    <label class="col-sm-2 control-label">标题</label>
    <div class="col-sm-10">
      <input type="text" name="newsTitle" class="form-control"  placeholder="" id="a">
    </div>
  </div>
  <div class="form-group">
    <label class="col-sm-2 control-label">作者</label>
    <div class="col-sm-4">
      <input type="text" name="newsWorker" class="form-control"  placeholder="" id="b">
    </div>
  </div>
  <div class="form-group" style="display: none">
    <label class="col-sm-2 control-label" >id</label>
    <div class="col-sm-4">
      <input type="text" name="newsId" class="form-control" id="e"  placeholder="">
    </div>
  </div>
  <div class="form-group">
    <label class="col-sm-2 control-label">类别</label> 
    <div class="col-sm-4">
      <select name="newsClassId" class="form-control" id="c"></select>
    </div>
  </div>
  
  <div class="form-group">
    <label class="col-sm-2 control-label">内容</label>
    <div class="col-sm-10">
      <textarea name="newsContent" class="form-control" style="height: 15em;" id="d"></textarea>
    </div>
      
  </div>
  
  <div class="form-group">
    <div class="col-sm-offset-2 col-sm-10">
    	<button type="submit" class="btn btn-primary _confirm">确定修改</button>
       <button type="button" class="btn btn-default" data-dismiss="modal">关闭修改</button>      
    </div>
  </div>
</form>
</div>
	 </div>
        </div>	
		<script src="js/jquery.min.js"></script>
		<script src="js/bootstrap.min.js"></script>
		<script type="text/javascript" src="web2/news-list.js"></script>
	    
	  
	</body>

</html>